/*
 * @Author: lusx 
 * @Date: 2020-05-25 15:53:55 
 * @Last Modified by: lusx
 * @Last Modified time: 2020-05-25 16:37:03
 */
import { observable, action } from 'mobx';
import { getProjectCount } from '../../apis/govern';
export default class {
    @observable pies = [];
    @observable count0 = [];
    @observable cardFootData = [];
    @observable loading = false;

    @action
    getProjectCount = (parmas = {}) => {
        this.loading = true;
        getProjectCount(parmas).then(result => {
            if (result.status === '1') {
                const { pies, count0, cardFootData } = result;
                this.pies = [...pies];
                this.count0 = [...count0];
                this.cardFootData = [...cardFootData];
            }
        })
            .catch((err) => { console.error('err', err) })
            .finally(() => { this.loading = false })
    }
}